home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / sys / amiga / programmer / 2133 < prev    next >
Encoding:
Internet Message Format  |  1996-08-05  |  1.0 KB

  1. Path: news.ifm.liu.se!d93marbl
  2. From: d93marbl@isy.liu.se (Martin Blom)
  3. Newsgroups: comp.sys.amiga.programmer
  4. Subject: Passing arguments to a thread
  5. Date: 27 Jan 1996 11:14:34 GMT
  6. Message-ID: <4ed1eq$nfi@newsy.ifm.liu.se>
  7. NNTP-Posting-Host: mut.isy.liu.se
  8. Mime-Version: 1.0
  9. Content-Type: text/plain; charset=iso-8859-1
  10. Content-Transfer-Encoding: 8bit
  11. X-Newsreader: NN version 6.5.0 #26 (NOV)
  12.  
  13. Is there a (nice) way to pass arguments to a new process?
  14. Right now I allocate some memory and copy the following code:
  15. Kick:
  16.      lea    kick(pc),a1
  17.      move.l #0,a0
  18.      jmp    ThreadStart
  19.  
  20. ... modify the #0 to point to my data structure, flush the cache and
  21.  start the process (which does FreeVec(a1)).
  22.  
  23. Somehow, this does not seem like a nice solution.
  24.  
  25. The code is located in a shared library.
  26.  
  27. --
  28.  +--------- Martin 'Leviticus' Blom ----------+    Commodore 128D 
  29.  | Linkoping Institute of Technology - Sweden |    Amiga 4000/040
  30.  +----------- lcs@lysator.liu.se -------------+
  31.                                   http://www.lysator.liu.se/~lcs/
  32.